<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>javaScript_HelloWorld</title>

    <script type="text/javaScript" src="HelloWorld.js"></script>

</head>
<body>
    <button onclick="alert('你点我干嘛');">点我一下</button> <!-- js代码写在标签中 -->
    <a href="javaScript:alert('你点我干嘛');">你也点我一下</a>
</body>
</html>